package com.linkhub.oms.admin.modules.shop.service;

import com.linkhub.oms.admin.modules.shop.domain.param.*;
import com.linkhub.oms.admin.modules.shop.domain.vo.AddShopVO;
import com.linkhub.oms.admin.modules.shop.domain.vo.AddShopVOV2;
import com.linkhub.oms.admin.modules.shop.domain.vo.ShopVO;

import javax.validation.Valid;
import java.util.List;

/**
 * @Description: ShopBizService
 * @Author: echo
 * @Date: 2024/3/20 21:13
 * @Version: 1.0
 */
public interface ShopBizService {

    /**
     * 查询商店列表
     *
     * @param shopQueryParam shopQueryParam
     * @return shops
     */
    List<ShopVO> listShops(ShopQueryParam shopQueryParam);

    /**
     * 新增商店
     *
     * @param addShopParam addShopParam
     * @return AddShopVO
     */
    AddShopVO saveShop(AddShopParam addShopParam);


    /**
     * 获取商店 access_token 并更新商店授权相关信息
     *
     * @param grantParam grantParam
     */
    void updateShopToken(AuthorizationGrantParam grantParam);

    /**
     * 更新商店为 token 未授权状态
     *
     * @param token token
     */
    void updateShopUnauthorized(String token);

    /**
     * 更新商店名称
     *
     * @param editShopParam editShopParam
     */
    void updateShopName(EditShopParam editShopParam);

    AddShopVOV2 saveShopV2( @Valid AddShopParamV2 addShopParamV2 );
}
